package com.sunny.ynhz.adapter;

import android.content.Context;

import com.chad.library.adapter.base.BaseMultiItemQuickAdapter;
import com.chad.library.adapter.base.BaseViewHolder;
import com.sunny.ynhz.R;
import com.sunny.ynhz.bean.NewsBean;
import com.sunny.ynhz.bean.SeasureAppBean;

import java.util.List;

/**
 * Created by huhuan123 on 2018/1/8.
 */

public class PatrolProblemAdapter extends BaseMultiItemQuickAdapter<SeasureAppBean.DataBean.ContentBean, BaseViewHolder> {
    Context context;
    List<SeasureAppBean.DataBean.ContentBean> newsData;
    Context mContext;

    public PatrolProblemAdapter(List<SeasureAppBean.DataBean.ContentBean> newsData,Context context) {
        super(newsData);
        addItemType(1, R.layout.item_partorl_problem1);
        this.newsData = newsData;
        this.mContext = context;

    }

    @Override
    protected void convert(BaseViewHolder helper, SeasureAppBean.DataBean.ContentBean item) {
        helper.setText(R.id.tv_type_content, item.getMatterName()).setText(R.id.tv_content, item.getDescribe()).setText(R.id.tv_report_man, "上报人:" + item.getUserName());
        helper.setText(R.id.tv_time, item.getTime());


    }
}
